package com.wn.user.util;

import java.util.Comparator;
import java.util.Map;

/**
 * @BelongsProject: shared_parking
 * @BelongsPackage: com.wn.user.util
 * @Author: 廖刚
 * @CreateTime: 2020-06-23 22:52
 * @Description:
 */
public class MapValueComparator implements Comparator<Map.Entry<String, Double>> {
    @Override
    public int compare(Map.Entry<String, Double> me1, Map.Entry<String, Double> me2) {
        //按照从大到小的顺序排列，如果想正序 调换me1 me2的位置
        return me1.getValue().compareTo(me2.getValue());
    }
}
